#include<stdio.h>
#include <string.h>
//#define IGNORE_SPACE 1
void str_cat(char dest[], const char src[])
{
    int i=strlen(dest),j=0;
    printf("len:%d\n",i);
    while (src[j]!='\0')
    { //如果不是空格就将第j个字符连接给dest后面
       #if defined IGNORE_SPACE
        
        if(src[j]==' ')
        {
            j++;
            continue;
        }
        #endif
        dest[i]=src[j];
        i++;       
        j++;
    }
    
}
int main(int argc, char const *argv[])
{
   char dest[100]={"Hello"},src[20]={" World"};
   //库函数里面的stcat
   str_cat(dest,src);
   printf("dest:%s\n",dest);
    return 0;
}
